<?php
/*
 * Copyright (c) 2022 Jack <Jacksoft@aliyun.com>.
 */
include("../includes/config.php");//全局文件
if (file_exists('../count/word_number.json')) {
    $number = json_decode(file_get_contents('../count/word_number.json'), true)['number'];
} else {
    $number = 0;
} 
$now = $number + 1;
$url= 'https://www.sybapi.cc/api/word?key='.$key;
$data = file_get_contents($url);// 获取数据
echo $data;
file_put_contents('../count/word_number.json', json_encode(['number' => $now]));
?>